package cn.com.cetccst.sdk.modelbiz;

import static cn.com.cetccst.sdk.modelbase.ConstantsAPI.COMMAND_SEND_AUTH;

import android.os.Bundle;
import android.text.TextUtils;
import android.util.Log;

import cn.com.cetccst.sdk.modelbase.BaseReq;
import cn.com.cetccst.sdk.modelbase.BaseResp;

public class SendAuth {

    public static final String TAG = "SelectGroupContact";

    public static class Resp extends BaseResp {
        public static final String SSAPI_SENDAUTH_RESP_OAUTHCODE = "ssapi_sendauth_resp_oauthcode";
        public String oAuthCode;

        public Resp() {
            super(COMMAND_SEND_AUTH);
        }

        public Resp(Bundle bundle) {
            this();
            this.fromBundle(bundle);
        }

        public void fromBundle(Bundle bundle) {
            super.fromBundle(bundle);
            oAuthCode = bundle.getString(SSAPI_SENDAUTH_RESP_OAUTHCODE);
        }

        public void toBundle(Bundle bundle) {
            super.toBundle(bundle);
            bundle.putString(SSAPI_SENDAUTH_RESP_OAUTHCODE, oAuthCode);
        }

        @Override
        public String toString() {
            return "Resp{" +
                    "errorCode=" + errorCode +
                    ", errorStr='" + errorStr + '\'' +
                    ", transaction='" + transaction + '\'' +
                    ", oAuthCode='" + oAuthCode + '\'' +
                    '}';
        }
    }

    public static class Req extends BaseReq {
        public Req() {
            super(COMMAND_SEND_AUTH);
        }

        public Req(Bundle var1) {
            this();
            this.fromBundle(var1);
        }

        @Override
        public String toString() {
            return "Req{" +
                    "type=" + type +
                    ", transaction='" + transaction + '\'' +
                    ", sdkVersion=" + sdkVersion +
                    ", appKey='" + appKey + '\'' +
                    '}';
        }
    }

}
